import axios from "axios";

export default {
  namespaced: true,
  state: {
    TableData: [],
  },
  mutations: {
    SET_TABLE_DATA(state, data) {
      state.TableData = data;
    },
  },
  actions: {
    async GetTable({ commit }) {
      const res = await axios({
        url: "http://localhost:10000/tableData",
      });
      commit("SET_TABLE_DATA", res.data);
    },
  },
};
